package com.gr.labbackend.controller.manage.material;

import com.alibaba.fastjson.JSONObject;
import com.gr.labbackend.service.manage.material.DeleteMaterialService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

@RestController
public class DeleteMaterialController {

    @Autowired
    private DeleteMaterialService deleteMaterialService;

    @PostMapping("/api/manage/material/delete-material")
    public JSONObject deleteMaterial(@RequestParam int id) {
        return deleteMaterialService.deleteMaterial(id);
    }

}
